<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="UTF-8">
<title>二级下拉菜单</title>
<style type="text/css">
/*
#193B5F 栏目字体颜色
*/
*{margin:0; padding:0}
body{width:960px; margin:20px auto; font-size:14px;}
/*导航条*/
#nav {background-color:blue; color:#fff;height:25px;line-height:25px;text-align:center;list-style:none;}
	#nav a{color:#fff;}
	#nav li{width:75px;float:left;position:relative;z-index:1;}
	#nav li .title{display:block;}
	#nav li .title:hover{background-color:green;}
	#nav li .submenu{width:75px;margin:0 auto;background:green;position:absolute;left:0;top:25px;display:none;}
	#nav li .submenu dd{border-top:1px dotted #ddd;color:#fff;}
</style>
</head>
<body>
<ul id="nav">
<!-- 有二级菜单的，给li加class="menu" 没有的不用加 -->
		<li class="menu">
			<a href="#" class="title">国家政务</a>
			<dl class="submenu">
				<dd><a href="#">时政要闻</a></dd>
				<dd><a href="#">远程党教</a></dd>
				<dd><a href="#">村务管理</a></dd>
			</dl>
		</li>
		<li>
			<a href="#" class="title">网络服务</a>
		</li>
		<li class="menu">
			<a href="#" class="title">信息交流</a>
			<dl class="submenu">
				<dd><a href="#">求购信息</a></dd>
				<dd><a href="#">转让信息</a></dd>
			</dl>
		</li>
</div><!--end nav-->
<script type="text/javascript">
<!--
var nav = document.getElementById("nav").childNodes;
for (var i=0;i<nav.length;i++)
{
	if (nav[i].className=="menu")
	{
		nav[i].onmouseover = function(){fnNav(this,"block")};
		nav[i].onmouseout = function(){fnNav(this,"none")};
	}
}
function fnNav(obj,flag)
{
	obj.getElementsByTagName("dl")[0].style.display = flag;
}
//-->
</script>
</body>
</html>